package view;

import javax.swing.JPanel;
import javax.swing.GroupLayout;
import javax.swing.GroupLayout.Alignment;
import javax.swing.JButton;
import javax.swing.JLabel;
import java.awt.Font;
import java.awt.Color;
import javax.swing.SwingConstants;
import javax.swing.JSeparator;
import javax.swing.JTextField;
import javax.swing.LayoutStyle.ComponentPlacement;

public class PaCodigosPostalesBaja extends JPanel {
	private static final long serialVersionUID = 1L;
	private JTextField txtCodigoPostal;

	/**
	 * Create the panel.
	 */
	public PaCodigosPostalesBaja() {
		
		JButton btnEliminarCodigoPostal = new JButton("Eliminar Codigo Postal");
		
		JLabel lblBaja = new JLabel("Baja de Codigo Postal");
		lblBaja.setHorizontalAlignment(SwingConstants.LEFT);
		lblBaja.setForeground(Color.BLUE);
		lblBaja.setFont(new Font("Sylfaen", Font.BOLD | Font.ITALIC, 18));
		
		JButton btCancelar = new JButton("Cancelar");
		
		JSeparator separator = new JSeparator();
		
		JLabel lblCodigoPostal = new JLabel("Codigo Postal");
		
		txtCodigoPostal = new JTextField();
		txtCodigoPostal.setColumns(10);
		GroupLayout groupLayout = new GroupLayout(this);
		groupLayout.setHorizontalGroup(
			groupLayout.createParallelGroup(Alignment.LEADING)
				.addGroup(groupLayout.createSequentialGroup()
					.addGap(10)
					.addComponent(lblBaja, GroupLayout.PREFERRED_SIZE, 199, GroupLayout.PREFERRED_SIZE)
					.addPreferredGap(ComponentPlacement.RELATED)
					.addComponent(btnEliminarCodigoPostal)
					.addPreferredGap(ComponentPlacement.RELATED)
					.addComponent(btCancelar))
				.addGroup(groupLayout.createSequentialGroup()
					.addGap(10)
					.addComponent(separator, GroupLayout.PREFERRED_SIZE, 440, GroupLayout.PREFERRED_SIZE))
				.addGroup(groupLayout.createSequentialGroup()
					.addGap(20)
					.addComponent(lblCodigoPostal, GroupLayout.PREFERRED_SIZE, 65, GroupLayout.PREFERRED_SIZE)
					.addPreferredGap(ComponentPlacement.RELATED)
					.addComponent(txtCodigoPostal, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE))
		);
		groupLayout.setVerticalGroup(
			groupLayout.createParallelGroup(Alignment.LEADING)
				.addGroup(groupLayout.createSequentialGroup()
					.addGroup(groupLayout.createParallelGroup(Alignment.LEADING)
						.addComponent(lblBaja)
						.addGroup(groupLayout.createSequentialGroup()
							.addGap(1)
							.addComponent(btCancelar))
						.addGroup(groupLayout.createSequentialGroup()
							.addGap(1)
							.addComponent(btnEliminarCodigoPostal, GroupLayout.PREFERRED_SIZE, 25, GroupLayout.PREFERRED_SIZE)))
					.addPreferredGap(ComponentPlacement.RELATED)
					.addComponent(separator, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)
					.addGap(18)
					.addGroup(groupLayout.createParallelGroup(Alignment.LEADING)
						.addGroup(groupLayout.createSequentialGroup()
							.addGap(3)
							.addComponent(lblCodigoPostal))
						.addComponent(txtCodigoPostal, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)))
		);
		setLayout(groupLayout);

	}
}
